// ***********************************************************************
// Project			: Micua
// Assembly         : Micua.Model
// Author           : iceStone
// Created          : 2013-11-23 15:28
//
// Last Modified By : iceStone
// Last Modified On : 2014-01-04 20:39
// ***********************************************************************
// <copyright file="Post.cs" company="Wedn.Net">
//     Copyright (c) Wedn.Net. All rights reserved.
// </copyright>
// <summary>缺少注释</summary>
// ***********************************************************************

namespace Micua.Model
{
    using System;
    using System.Collections.Generic;
    
    /// <summary>
    /// 用户 实体类.
    /// </summary>
    /// <remarks>
    ///  2013-11-18 19:40 Created By iceStone
    /// </remarks>
    public partial class User
    {
        public User()
        {
            this.NickName = string.Empty;
            this.Email = string.Empty;
            this.Link = string.Empty;
            this.Status = 0;
            this.Role = 2;
            this.Description = string.Empty;
            this.Metas = new HashSet<UserMeta>();
            this.Posts = new HashSet<Post>();
            this.Comments = new HashSet<Comment>();
        }
    
        /// <summary>
        /// 设置或读取Id字段.
        /// </summary>
        /// <value>Id字段.</value>
        public int Id { get; set; }
        /// <summary>
        /// 设置或读取登录名。
        /// </summary>
        /// <value>登录名.</value>
        public string Login { get; set; }
        /// <summary>
        /// 设置或读取昵称。
        /// </summary>
        /// <value>昵称.</value>
        public string NickName { get; set; }
        /// <summary>
        /// 设置或读取登录密码。
        /// MD5Lower
        /// </summary>
        /// <value>登录密码.</value>
        public string Password { get; set; }
        /// <summary>
        /// 设置或读取用户邮箱。
        /// </summary>
        /// <value>用户邮箱.</value>
        public string Email { get; set; }
        /// <summary>
        /// 设置或读取用户链接地址。
        /// </summary>
        /// <value>用户链接地址.</value>
        public string Link { get; set; }
        /// <summary>
        /// 设置或读取注册时间。
        /// </summary>
        /// <value>注册时间.</value>
        public System.DateTime RegDate { get; set; }
        /// <summary>
        /// 设置或读取用户状态。
        /// 0:正常;1:等待审核;2:禁止
        /// </summary>
        /// <value>用户状态.</value>
        public byte Status { get; set; }
        /// <summary>
        /// 设置或读取用户角色等级。
        /// 0:超级管理员;1:撰写者;2:订阅者;3:第三方登录用户
        /// </summary>
        /// <value>用户角色等级.</value>
        public short Role { get; set; }
        /// <summary>
        /// 设置或读取用户描述。
        /// </summary>
        /// <value>用户描述.</value>
        public string Description { get; set; }
    
        /// <summary>
        /// 设置或读取用户元数据集合。
        /// </summary>
        /// <value>用户元数据集合.</value>
        public virtual ICollection<UserMeta> Metas { get; set; }
        /// <summary>
        /// 设置或读取用户文章集合。
        /// </summary>
        /// <value>用户文章集合.</value>
        public virtual ICollection<Post> Posts { get; set; }
        /// <summary>
        /// 设置或读取Comments.
        /// </summary>
        /// <value>Comments.</value>
        public virtual ICollection<Comment> Comments { get; set; }
    }
}
